//******************************************************************************
//this code is protected by the GNU affero GPLv3
//author:Sylvain BERTRAND <sylvain.bertrand AT gmail dot com>
//                        <digital.ragnarok AT gmail dot com>
//******************************************************************************
#include "globals.h"

s8 wl_shm_pool_buffer_req(struct client *c,s32 shm_pool_buffer_slot,
                                                                  struct msg *m)
{
  s8 r;
  switch(m->req_op){
  case WL_BUFFER_DESTROY:
    LOG_WIRE("client(%d):shm_pool_buffer::destroy shm_pool_buffer_id=%u\n",
                                                               c->so,m->req[0]);
    r=shm_pool_buffer_destroy(c,shm_pool_buffer_slot);
    break;
  default:
    PERR("client(%d):fatal:shm_pool_buffer unknown opcode %u\n",c->so,
                                                                     m->req_op);
    r=LWL_ERR;
  };
  return r;
}
